package com.city.service.report.impl;

import com.city.domain.report.CtTask;
import com.city.repository.report.CtTaskRepository;
import com.city.service.report.CtTaskService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class CtTaskServiceImpl implements CtTaskService {

    @Autowired
    private CtTaskRepository ctTaskRepository;

    @Override
    public void save(CtTask ctTask) {
        ctTaskRepository.save(ctTask);
    }

    @Override
    public void updateWorkTime(String workTime, Integer taskId) {
        ctTaskRepository.updateWorkTime(workTime,taskId);
    }

    @Override
    public void updateCheckTime(String checkTime, Integer taskId) {
        ctTaskRepository.updateCheckTime(checkTime,taskId);
    }

    @Override
    public CtTask findByTaskId(Integer id) {
        return ctTaskRepository.findByTaskId(id);
    }

    @Override
    public void updateFinishTime(String finishTime, Integer taskId) {
        ctTaskRepository.updateFinishTime(finishTime,taskId);
    }

    @Override
    public void updateReworkComment(String comment, Integer taskId) {
        ctTaskRepository.updateReworkComment(comment,taskId);
    }

    @Override
    public void updateCaseComment(String comment, Integer taskId) {
        ctTaskRepository.updateCaseComment(comment,taskId);
    }
}
